// test-auth.js
import { registerUser, loginUser } from '../src/services/authService.js';

async function testAuth() {
  try {
    console.log('Testing user registration...');
    const result = await registerUser('testuser', 'test@example.com', 'password123');
    console.log('Registration result:', result);
    
    console.log('\nTesting user login...');
    const loginResult = await loginUser('testuser', 'password123');
    console.log('Login result:', loginResult);
    
  } catch (error) {
    console.error('Error:', error.message);
  }
}

testAuth();